package com.basic;

import com.frame.struts.BaseBean;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.frame.struts.ActionContext;
import com.utils.*;


/**
 * <p>Title: </p>
 * <p>Description: </p>
 * <p>Copyright: Copyright (c) 2006</p>
 * <p>Company: </p>
 * @author not attributable
 * @version 1.0
 */

public class OtherChangeForm extends BaseBean {
    public OtherChangeForm() {
    }
	OtherChangeEntity ae = new OtherChangeEntity();
/*public String addOtherChange(){
		HttpServletRequest request = ActionContext.getActionContext().
			getRequest();
		HttpServletResponse response = ActionContext.getActionContext().
			getResponse();
		BasicFactory factory = new BasicFactory();
		String qyid = (String) request.getSession().getAttribute("session_qyid");
		ae.setQyid(qyid);
		ae.setXh(factory.getNextXh("qy_qtbg", qyid));
		try{
	    	if(factory.addOtherChange(ae)){
				response.sendRedirect("/basic/modifyOtherChange.jsp");
		    }
		   else
		   {
		        response.sendRedirect("/basic/failed.jsp");
		   }
		}
		catch (Exception e) {
		}
			return null;
	}*/
	
	public String modifyOtherChange(){
		HttpServletRequest request = ActionContext.getActionContext().
			getRequest();
		HttpServletResponse response = ActionContext.getActionContext().
			getResponse();
		BasicFactory factory = new BasicFactory();
		String qyid = (String) request.getSession().getAttribute("session_qyid");
		ae.setQyid(qyid);
		//factory.deleteAssociationAgent(qyid);
		try{
			if(factory.addOtherChange(ae)){
				response.sendRedirect("/basic/modifyOtherChange.jsp");
		    }
			else
			{
		        response.sendRedirect("/basic/failed.jsp");
			}
		}
		catch (Exception e) {

		}

		return null;

	}


	public void setQtbgqk(String qtbgqk){
		ae.setQtbgqk(qtbgqk);
	}
	public String getQtbgqk(){
		return ae.getQtbgqk();
	}

	public void setQyid(String qyid){
		ae.setQyid(qyid);
	}
	public String getQyid(){
		return ae.getQyid();
	}
	public int getXh(){
		return ae.getXh();
	}
	public void setXh(int xh){
		ae.setXh(xh);
	}


}